package mirrormonkey.framework;

import mirrormonkey.util.netevent.server.ServerEventManager;

import com.jme3.network.Server;

public class ServerSyncAppState extends SyncAppState<ServerEventManager> {

	public final Server server;

	public ServerSyncAppState(Server server) {
		this(new EntityProvider(), new ServerEventManager(), server);
	}

	public ServerSyncAppState(EntityProvider entityProvider,
			ServerEventManager eventManager, Server server) {
		super(entityProvider, eventManager);
		server.addMessageListener(eventManager.getMessageListener());
		server.addConnectionListener(eventManager.getConnectionListener());
		this.server = server;
	}

	@Override
	protected boolean isCollectLocalConstructors() {
		return false;
	}

}
